import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'

// https://vitejs.dev/config/
export default defineConfig({
  plugins: [vue()],
  resolve:{
    //添加别名 将@替换为src
    alias:[
      {
        find: "@",replacement: "/src"
      }
    ]
  },
  server: {
    port: 80,
    host: true,
    open: true,
  /*  proxy: {
      // https://cn.vitejs.dev/config/#server-proxy
      '/dev-api': {
        target: 'http://localhost:8080',
        changeOrigin: true,
        rewrite: (p) => p.replace(/^\/dev-api/, '')
      }
    }*/
  }
})
